package com.tjetc.view;

import com.tjetc.view.manage.*;

import java.util.Scanner;

public class AdminMangeView {
    static Scanner sc = new Scanner(System.in);
    public void start()
    {
        while(true){
            try {
                System.out.println("1.对管理员表进行操作");
                System.out.println("2.对医护人员表进行操作");
                System.out.println("3.接生!,对家长表进行操作");
                System.out.println("4.检查!对疾病表进行操作");
                System.out.println("5.接种!,对疫苗表进行操作");
                System.out.println("6.出院!,为新生儿生成身份证");
                System.out.println("0.返回上一级");
                int i= sc.nextInt();
                switch (i){
                    case 1:
                        new AdminView().start();
                        break;
                    case 2:
                        new DoctorView().start();
                        break;
                    case 3:
                        new ParentsView().start();
                        break;
                    case 4:
                        new DiseaseView().start();
                        break;
                    case 5:
                        new VaccineView().start();
                        break;
                    case 6:
                        new IdCardView().start();
                        break;
                    case 0:
                        return;
                }
            } catch (Exception e) {
                System.out.println("输入错误,请重新输入");
                sc.nextLine();
            }
        }
    }
}
